export type ValueSelector = string[] // [nodeId, key | obj key path]

export enum ChangeType {
  changeVarName = 'changeVarName',
  remove = 'remove'
}

export type InputVar = {
  id: string
  variable: string
  type: string
  label: string
  value: string
  max_length?: number
  default?: string
  required: boolean
  hint?: string
  options?: any[]
  value_selector?: ValueSelector // type为引用(cite)时智能体类型时，value_selector存[id,variable]时,value存id,variable，方便回显
  valuet? : string
}

export type MoreInfo = {
  type: ChangeType
  payload?: {
    beforeKey: string
    afterKey?: string
  }
}

export type OutputVar = {
  id: string
  variable: string
  type: string
  label: string
  value: string
  max_length?: number
  default?: string
  required: boolean
  hint?: string
  options?: any[]
  value_selector?: ValueSelector // type为引用(cite)时智能体类型时，value_selector存[id,variable]时,value存id,variable，方便回显
}
